#include "ch02.h"
int main()
{
	// 尝试使用 fread 和 fwrite 连接2个文件
	FILE * stream;
	FILE * stream2;
	int x;
	char buf[80];
	stream2 = fopen("test_file2", "r");
	x = fread(buf, 40, 1, stream2);
	printf("text = %s", buf);


	stream = fopen("test_file", "a");
	x = fwrite(buf, 40, 1, stream);
	close(stream);
	close(stream2);
	return 0;
}
